//
//  GLAConstant.h
//  GLASDK_Overseas
//
//  Created by linan on 2025/5/9.
//

#import <Foundation/Foundation.h>
#import "GLAResponseModel.h"

typedef NS_ENUM(NSInteger,GLAEventType){
    GLAEventTypeofInitFinish        = 0,    //初始化完成
    GLAEventTypeofLoginSuccess      = 1,    //登录成功
    GLAEventTypeofLoginFail         = 2,    //登录失败
    GLAEventTypeofPaySuccess        = 3,    //支付成功
    GLAEventTypeofPayFail           = 4,    //支付失败
    GLAEventTypeofPayCancel         = 5,     //支付取消
    GLAEventTypeofUMP               = 6,      //UPM
    GLAEventTypeofConfigSuccess     = 7,      //获取配置成功
    GLAEventTypeofConfigFail        = 8      //获取配置失败
};

typedef NS_ENUM (int,GLALoginType){
    GLALoginTypeofGuest             = 0,    //游客登录
    GLALoginTypeofFacebook          = 1,    //Facebook登录
    GLALoginTypeofGoogle            = 2,    //Google登录
    GLALoginTypeofApple             = 7,    //Apple登录
    GLALoginTypeofTwitter           = 20,    //Twitter登录
    GLALoginTypeofEmail             = 9999, // 邮箱登录
};

typedef NS_ENUM(NSInteger,GLAShareResult){
    GLAShareResultSuccess           = 0,
    GLAShareResultCancel            = 1,
    GLAShareResultFail              = 2,
};

// 隐私协议状态
typedef NS_ENUM(NSInteger,GLAPrivacyStatus){
    GLAPrivacyNoOpen           = -1,//未开启/未获取
    GLAPrivacyRefuse           = 0,//拒绝
    GLAPrivacyAgree            = 1,//同意
};

typedef enum{
    Push_NotOpenState = 0,     //未集成
    Push_DeniedState = 1,      //拒绝
    Push_AuthorizedState = 2,  //同意
} GLAPushNotifiState;  //通知权限状态


typedef enum{
    Login = 0,     //登录
    Bind = 1,  //绑定
    Change_bind_before = 2,  //绑定前（换绑给原来的邮箱发验证码）
    Change_Bind = 3,  //换绑
} GLAEmailType;  //邮箱发送验证码类型

typedef enum{
    webviewCallbackTypeClose = 0,       //关闭
} webviewCallbackType;

typedef void (^ResponseBlock)(BOOL success, GLAResponseModel *response);

typedef void (^shareBlock)(GLAShareResult result, NSString *errMsg);

typedef void (^UMPPrivacyBlock)(BOOL isShowUMPView);

typedef void (^ImageUploadResultBack)(ImageUploadResult *result);
typedef void (^ImageStatusResultBack)(ImageStatusResult *result);

typedef void(^agreeComplianceCallback)(GLAPrivacyStatus status);

// 推送权限状态回调
typedef void(^CallBackPushNotifiState)(GLAPushNotifiState state);

// webview的操作回调给游戏
typedef void(^webviewCallback)(webviewCallbackType type);
// CMP结果回调
typedef void (^BCEUCMPCallback)(BOOL agreed, GLACMPResult *result);


